package cn.dlc.com.user.controller;

import cn.dlc.com.user.model.User;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpSession;

/**
 * @author 邓立川
 * @date 2021/11/21 10:15
 * @desc 当前类的描述信息
 */
@RestController
// 后面这个用来设置编码的
@RequestMapping(value = "user",produces = {"text/plain;charset=UTF-8"})
public class UserController {


    @PostMapping("/login-success")
    public String authentication() {

        return "登录成功";
    }


    @GetMapping("r/r1")
    public String resource1(HttpSession session){

        return "资源1";
    }

    @GetMapping("r/r2")
    public String resource2(HttpSession session){

        return "资源2";
    }
}
